#pragma once

#include <gofcl_usbfs_r.h>

typedef struct {
	u32_s GINTEN : 1;
	u32_s : 6;
	u32_s TXFTH : 1;
	u32_s PTXFTH : 1;
	u32_s : 23;
} usbfs_gahbcs_s;

_Static_assert(sizeof(usbfs_gahbcs_s) == 4,
	       "Struct usbfs_gahbcs_s defined error!");

static inline void usbfs_wreg_gahbcs_s(usbfs_gahbcs_s gahbcs) {
	union {
		usbfs_gahbcs_s g;
		u32_s u;
	} gu = {
		.g = gahbcs,
	};
	usbfs_wreg(USBFS_GAHBCS_R, gu.u);
}
